<?php
//
//-------------------------------------------------
// | CreateTime: 2020/8/28 15:19
//+------------------------------------------------
// | Author: chenxueyuan
//+------------------------------------------------
// | Describe: ...
//+------------------------------------------------

namespace app\index\controller;


use think\Controller;

class Common extends Controller
{
    public function initialize()
    {
        $article_model= new \app\admin\model\Article();
       $article_select_orderByUpdateTime=$article_model->order('update_time','desc')->limit(6)->select();
        $article_select_orderByClicks=$article_model->order('clicks','desc')->limit(6)->select();
        $tags_select=db('tags')->select();
        $this->assign('article_select_orderByUpdateTime',$article_select_orderByUpdateTime);
        $this->assign('article_select_orderByClicks',$article_select_orderByClicks);
        $this->assign('tags_select',$tags_select);
    }
}